	.file	"server.c"
	.section	.rodata
.LC0:
	.string	"socket"
.LC1:
	.string	"bind"
.LC2:
	.string	"accept"
.LC3:
	.string	"accept client %s/n"
	.align 8
.LC4:
	.string	"Welcome to my server/n \345\256\242\346\210\267\347\253\257IP127.0.0.305/n \346\234\215\345\212\241\345\231\250\345\256\236\347\216\260\350\200\205\345\255\246\345\217\26720155305/n \345\275\223\345\211\215\346\227\266\351\227\2642017.11.8/n"
.LC5:
	.string	"%s/n"
.LC6:
	.string	"write"
	.text
	.globl	main
	.type	main, @function
main:
.LFB2:
	.cfi_startproc
	pushq	%rbp
	.cfi_def_cfa_offset 16
	.cfi_offset 6, -16
	movq	%rsp, %rbp
	.cfi_def_cfa_register 6
	subq	$8272, %rsp
	movl	%edi, -8260(%rbp)
	movq	%rsi, -8272(%rbp)
	movq	%fs:40, %rax
	movq	%rax, -8(%rbp)
	xorl	%eax, %eax
	leaq	-8240(%rbp), %rax
	movl	$16, %edx
	movl	$0, %esi
	movq	%rax, %rdi
	call	memset
	movw	$2, -8240(%rbp)
	movl	$0, -8236(%rbp)
	movl	$8000, %edi
	call	htons
	movw	%ax, -8238(%rbp)
	movl	$0, %edx
	movl	$1, %esi
	movl	$2, %edi
	call	socket
	movl	%eax, -8252(%rbp)
	cmpl	$0, -8252(%rbp)
	jns	.L2
	movl	$.LC0, %edi
	call	perror
	movl	$1, %eax
	jmp	.L8
.L2:
	leaq	-8240(%rbp), %rcx
	movl	-8252(%rbp), %eax
	movl	$16, %edx
	movq	%rcx, %rsi
	movl	%eax, %edi
	call	bind
	testl	%eax, %eax
	jns	.L4
	movl	$.LC1, %edi
	call	perror
	movl	$1, %eax
	jmp	.L8
.L4:
	movl	-8252(%rbp), %eax
	movl	$5, %esi
	movl	%eax, %edi
	call	listen
	movl	$16, -8256(%rbp)
	leaq	-8256(%rbp), %rdx
	leaq	-8224(%rbp), %rcx
	movl	-8252(%rbp), %eax
	movq	%rcx, %rsi
	movl	%eax, %edi
	call	accept
	movl	%eax, -8248(%rbp)
	cmpl	$0, -8248(%rbp)
	jns	.L5
	movl	$.LC2, %edi
	call	perror
	movl	$1, %eax
	jmp	.L8
.L5:
	movl	-8220(%rbp), %eax
	movl	%eax, %edi
	call	inet_ntoa
	movq	%rax, %rsi
	movl	$.LC3, %edi
	movl	$0, %eax
	call	printf
	movl	-8248(%rbp), %eax
	movl	$0, %ecx
	movl	$21, %edx
	movl	$.LC4, %esi
	movl	%eax, %edi
	call	send
	movl	%eax, -8244(%rbp)
	jmp	.L6
.L7:
	movl	-8244(%rbp), %eax
	cltq
	movb	$48, -8208(%rbp,%rax)
	leaq	-8208(%rbp), %rax
	movq	%rax, %rsi
	movl	$.LC5, %edi
	movl	$0, %eax
	call	printf
	movl	-8244(%rbp), %eax
	movslq	%eax, %rdx
	leaq	-8208(%rbp), %rsi
	movl	-8248(%rbp), %eax
	movl	$0, %ecx
	movl	%eax, %edi
	call	send
	testq	%rax, %rax
	jns	.L6
	movl	$.LC6, %edi
	call	perror
	movl	$1, %eax
	jmp	.L8
.L6:
	leaq	-8208(%rbp), %rsi
	movl	-8248(%rbp), %eax
	movl	$0, %ecx
	movl	$8192, %edx
	movl	%eax, %edi
	call	recv
	movl	%eax, -8244(%rbp)
	cmpl	$0, -8244(%rbp)
	jg	.L7
	movl	-8248(%rbp), %eax
	movl	%eax, %edi
	movl	$0, %eax
	call	close
	movl	-8252(%rbp), %eax
	movl	%eax, %edi
	movl	$0, %eax
	call	close
	movl	$0, %eax
.L8:
	movq	-8(%rbp), %rcx
	xorq	%fs:40, %rcx
	je	.L9
	call	__stack_chk_fail
.L9:
	leave
	.cfi_def_cfa 7, 8
	ret
	.cfi_endproc
.LFE2:
	.size	main, .-main
	.ident	"GCC: (Ubuntu 5.4.0-6ubuntu1~16.04.5) 5.4.0 20160609"
	.section	.note.GNU-stack,"",@progbits
